package com.bawei.module_move.vm

import com.bawei.http.CommonHttpRetrofitAnnotation
import com.bawei.module_move.api.MoveApiServer
import dagger.Module
import dagger.Provides
import dagger.hilt.InstallIn
import dagger.hilt.components.SingletonComponent
import retrofit2.Retrofit
import javax.inject.Inject
import javax.inject.Singleton

@Module
@InstallIn(SingletonComponent::class)
object MoveSrverModule {

    /**
     * 暴露一个获取HomeApiServer实例方法
     */
    @Provides
    @Singleton
    fun getHomeApiServer(@CommonHttpRetrofitAnnotation retrofit: Retrofit): MoveApiServer = retrofit.create(MoveApiServer::class.java)
}